<template>
  <wd-navbar :leftArrow="!isMain && leftArrow" :title="title" :safeAreaInsetTop="true" :bordered="false" :fixed="fixed"
    :placeholder="placeholder" :custom-class="customClass" @click-left="toBack">
    <template #left>
      <view class="flex items-center gap-x-1" slot="left" v-if="isMain">
        <wd-img src="/static/logo.png" width="48rpx" height="64rpx" mode="aspectFill"></wd-img>
        <image src="/static/title.png" class="w-[331rpx] ml-4" mode="widthFix"></image>
      </view>
      <wd-icon name="thin-arrow-left" :color="arrowColor" size="36rpx" v-else-if="leftArrow"></wd-icon>
    </template>
  </wd-navbar>
</template>
<script setup>
import { toBack } from "@/utils/navigation";
const props = defineProps({
  leftArrow: {
    type: Boolean,
    default: true,
  },
  arrowColor: {
    type: String,
    default: '#010101',
  },
  customClass: {
    type: String,
    default: '',
  },
  title: {
    type: String,
    default: '',
  },
  fixed: {
    type: Boolean,
    default: false,
  },
  placeholder: {
    type: Boolean,
    default: false,
  },
  isMain: {
    type: Boolean,
    default: false,
  },
})
</script>
<style lang="less" scoped></style>
